package com.test.singleton;

public enum Singleton2 {

    INSTANCE;//属性

    public static void main(String[] args) {
        Singleton2 singleton2 = Singleton2.INSTANCE;
        Singleton2 singleton1 = Singleton2.INSTANCE;
        System.out.println(singleton1.hashCode());
        System.out.println(singleton2.hashCode());
    }
}

